<%@ page contentType="text/html;charset=UTF-8"%>
<%@ include file="/commons/taglibs.jsp"%>
<html>
	<head>
		<title>页面标题</title>
		<%@ include file="/commons/meta.jsp"%>
		<script language=javascript src="${ctx}/scripts/date/wpCalendar.js"></script>
		
		<script type="text/javascript">
			/**验证和提交表单*/
			function validate(){
				var msg = "";
				var title = document.BacklogForm.title.value;
				if(title == "") {msg += "--主题不能为空;\n";} else if(title.length > 20){msg += "--主题长度不能超过20个字符;\n";}

				var status = document.BacklogForm.status.value;
				if(status == "") {msg += "--状态不能为空;\n";} else if(status.length > 20){msg += "--状态长度不能超过20个字符;\n";}

				var type = document.BacklogForm.type.value;
				if(type == "") {msg += "--类型不能为空;\n";} else if(type.length > 20){msg += "--类型长度不能超过20个字符;\n";}

				var sendMan = document.BacklogForm.sendMan.value;
				var sendManP = /^[0-9]{1,20}$/;
				if(!sendManP.exec(sendMan)){msg += "--发起人必须为数字;\n";}

				var sendDate = document.BacklogForm.sendDate.value;
				if(sendDate == "") {msg += "--发送时间不能为空;\n";}

				var url = document.BacklogForm.url.value;
				if(url == "") {msg += "--执行URL不能为空;\n";} else if(url.length > 20){msg += "--执行URL长度不能超过20个字符;\n";}

				if(msg != "") {alert(msg);} else {document.BacklogForm.submit();}

			}
		</script>
	</head>
	<body>

		<div class="albox">
			<!--统一信息头部开始-->
			<ul>
				<li>
					<img src="${templateVo.styleImagePath}/list9.gif" />
				</li>
				<li style="width: 99%">
					<table width="100%" border="0" cellspacing="0" cellpadding="0"
						align="center" class="albox1">
						<tr>
							<td width="2%" align="right" height="31">
								<img src="${templateVo.styleImagePath}/ico_clock3.gif" />
							</td>
							<td width="4%">
								<a href="javascript:void(validate())">保存</a>
							</td>
							<td width="2%">
								<img src="${templateVo.styleImagePath}/ico_clock1.gif" />
							</td>
							<td width="4%">
								<a href="javascript:void(history.back())">返回</a>
							</td>
							<td width="84%"></td>
						</tr>
					</table>
				</li>
				<li style="float: right;">
					<img src="${templateVo.styleImagePath}/list10.gif" />
				</li>
			</ul>
			<!--统一信息头部结束-->
		</div>

		<div style="width: 98%; float: left;">
			<table width="98%" border="0" cellspacing="0" cellpadding="0"
				align="center">
				<tr>
					<td class="edittit" align="center">
						XX编辑
					</td>
				</tr>
				<tr>
					<td align="center">
						&nbsp;
					</td>
				</tr>
			</table>
			<html:form action="/BacklogAction.do" styleClass="form">
				<input type="hidden" name="method" value="save" />
				<html:hidden property="id" />
				<table width="98%" border="1" cellspacing="1" cellpadding="2">
				    
					<tr class=tr001>
						<td width=12% class='text12_1' align=right bgcolor='#F7F7F7'>主题：</td>
						<td bgcolor='#Ffffff'><html:text property="title" styleClass="text"/><font color=red>(*)</font></td>
					</tr>
					<tr class=tr001>
						<td width=12% class='text12_1' align=right bgcolor='#F7F7F7'>状态：</td>
						<td bgcolor='#Ffffff'><html:text property="status" styleClass="text"/><font color=red>(*)</font></td>
					</tr>
					<tr class=tr001>
						<td width=12% class='text12_1' align=right bgcolor='#F7F7F7'>类型：</td>
						<td bgcolor='#Ffffff'><html:text property="type" styleClass="text"/><font color=red>(*)</font></td>
					</tr>
					<tr class=tr001>
						<td width=12% class='text12_1' align=right bgcolor='#F7F7F7'>发起人：</td>
						<td bgcolor='#Ffffff'><html:text property="sendMan" styleClass="text"/><font color=red>(*)</font></td>
					</tr>
					<tr class=tr001>
						<td width=12% class='text12_1' align=right bgcolor='#F7F7F7'>发送时间：</td>
						<td bgcolor='#Ffffff'><html:text property="sendDate" onfocus="showCalendar(this)" readonly="true" styleClass="text"/><font color=red>(*)</font></td>
					</tr>
					<tr class=tr001>
						<td width=12% class='text12_1' align=right bgcolor='#F7F7F7'>执行URL：</td>
						<td bgcolor='#Ffffff'><html:text property="url" styleClass="text"/><font color=red>(*)</font></td>
					</tr>

				</table>
			</html:form>
		</div>
	</body>
</html>
